<?php

/* @var $this yii\web\View */

use yii\helpers\Html;
use yii\widgets\ActiveForm;
//use app\assets\SmartWizardAsset;
//SmartWizardAsset::register($this);

$this->title = '选择充值通道';
$this->params['breadcrumbs'][] = $this->title;
?>
<!-- page title -->
<div class="page-title">
  <div>
    <h1><i class="fa fa-trophy"></i> 选择充值通道</h1>
    <p style="font-style:normal;">会员手动填写充值金额，点击确定按钮，调取个人支付宝二维码支付页面</p>
  </div>
  <div style="width:300px;">
    <ul class="breadcrumb">
      <li><i class="fa fa-home fa-lg"></i></li>
      <li><a href="#">充值和提现</a></li>
      <li><a class='active' href="#">充值通道</a></li>
    </ul>
  </div>
</div>
<!-- page title end-->

<!-- page body start -->
<div class="card">
  <?php $form = ActiveForm::begin(); ?>
<?php
$dbchannel = $this->context->sysConfig->pay_channel;
$allchannels = explode(',',$paychannel);
$channellist=[];
$channeltip=[];
$j=0;
$channelinfo=[
  '0'=>{
    'label'=>'网银支付',
    'hint'=>'充值1元---5万元，请选择网银支付'
  },
  '1'=>{
    'label'=>'支付宝支付通道',
    'hint'=>'充值1元---1万元，请选择支付宝'
  },
  '2'=>{
    'label'=>'微信支付通道',
    'hint'=>'充值1元---2000元，请选择微信支付'
  }
];
for($i=0;$i<count($allchannels);$i++){
  if($allchannels[$i]==1){
    $channellist[$i]=$channelinfo[$i]->label;
    $channeltip[$i]=$channelinfo[$i]->tip;
  }
}
$channeltiptext=implode(';',$channeltip);
$form->field($model, 'channel')->dropDownList($channellist)
->hint('说明：'.$channeltiptext);
?>
<button type="submit" class="btn btn-warning">下一步</button>
<?php ActiveForm::end(); ?>
</div>
<!-- page body end-->
